﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class Topics_Topics_Charts : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!this.IsPostBack)
        {
            CMSModel.CMSEntities cms = new CMSModel.CMSEntities();
            int tid =int.Parse( Request["tid"]);
            Repeater1.DataSource = cms.Topics2Charts.Where(x => x.Tid == tid).Select(x => new { x.Id, x.IsBigImg, path = "/cms/file/" + x.Path,x.Title,x.Tid});
            Repeater1.DataBind();
        }
    }
    protected void btnAdd_Click(object sender, EventArgs e)
    {
        Response.Redirect("Topics_Charts_detail.aspx?tid=" + Request["tid"]);
    }
}